package ar.org.cfired.expedientes;
import java.util.HashMap;
import java.util.Map;

import org.jbpm.api.Configuration;
import org.jbpm.api.ExecutionService;
import org.jbpm.api.ProcessInstance;
public class GenerarDocumentoExpedientes {

	 public static void main(String[] args) {
	        ExecutionService executionSe = new Configuration().buildProcessEngine().getExecutionService();
	        ExecutionService executionService = new Configuration().buildProcessEngine().getExecutionService();
	        ProcessInstance processInstance = null;
	        Map<String, Object> variables = new HashMap<String, Object>();
	        //variables.put("expediente", "65550001");
	        variables.put("expediente", "28740017");
	        variables.put("usuariosConsultados", "fbarletta,rogelio");
	        processInstance = executionService.startProcessInstanceByKey("Expedientes", variables);
	        System.out.println(processInstance.getState());
	    }
}
